C     =============================================================70
C     Declare the common variables
C     by Guan Guoqiang at 22-7-2011
      MODULE DCMD_CMOD
      
C     Common variables declaration
C     Common area - GeoParams, to store the global variables of
C                              tube-side and shell-side geometric 
C                              parameters
C                   COM_ID: inner diameters
C                   COM_OD: outer diameters
C                   COM_DEQ: equivalent diameter
C                   COM_CSA: cross section area
      REAL*8 COM_ID(2), COM_OD(2), COM_DEQ(2), COM_CSA(2)
      COMMON /GeoParas/ COM_ID, COM_OD, COM_DEQ, COM_CSA
      
C     Common area - MemProps, to store the global variables of
C                             membrane properties
C                   COM_NUM: number of hollow fiber tubes
C                   COM_LEN: membrane length
C                   COM_THK: membrane thickness
C                   COM_ALOC: local membrane area
C                   COM_PERM: membrane permeability
C                   COM_COND: membrane thermal conductivity
      REAL*8 COM_NUM, COM_LEN, COM_THK, COM_ALOC, COM_PERM, COM_COND
      COMMON /MemProps/ COM_NUM, COM_LEN, COM_THK, COM_ALOC, 
     &                  COM_PERM, COM_COND
      
C     Common area - StmProps, to store the global variables of
C                             tube-side and shell-side stream's
C                             properties
C                   COM_RHO: density
C                   COM_MU: viscosity
C                   COM_LAMBDA: thermal conductivity
C                   COM_CP: heat capacity
      REAL*8 COM_RHO(2), COM_MU(2), COM_LAMBDA(2), COM_CP(2)
      COMMON /StmProps/ COM_RHO, COM_MU, COM_LAMBDA, COM_CP
      
C     Common area - ComRVars, to store the global real variables
C                   COM_WIN - inlet mass flowrates
C                   COM_TIN - inlet temperatures
C                   COM_PIN - inlet pressures
C                   COM_VIN - inlet velocities
C                   COM_WOUT - outlet mass flowrates
C                   COM_TOUT - outlet temperatures
C                   COM_POUT - outlet pressures
C                   COM_VOUT - outlet velocities
C                   COM_WLOC - mass flowrates at the node
C                   COM_PLOC - pressure at the node
C                   COM_HLOC - heat transfer film coefficients at the 
C                              node
C                   COM_XLOC - NaCl mole fraction in the feed stream
      REAL*8 COM_WIN(2), COM_TIN(2), COM_PIN(2), COM_VIN(2),
     &       COM_WOUT(2), COM_TOUT(2), COM_POUT(2), COM_VOUT(2),
     &       COM_WLOC(2), COM_TLOC(2), COM_PLOC(2), COM_VLOC(2),
     &       COM_HLOC(2), COM_XLOC
      COMMON /ComRVars/ COM_WIN, COM_TIN, COM_PIN, COM_VIN,
     &                  COM_WOUT, COM_TOUT, COM_POUT, COM_VOUT,
     &                  COM_WLOC, COM_TLOC, COM_PLOC, COM_VLOC,
     &                  COM_HLOC, COM_XLOC
C     Common area - ComIVars, to store the global integer variables
C                   COM_OPT - running option
      INTEGER COM_OPT
      COMMON /ComIVars/ COM_OPT
      
      END MODULE DCMD_CMOD